<template>
  <ul class="nav-bar">
    <li class="back" @click="back">返回</li>
    <li class="title">{{$route.meta.title}}</li>
    <li class="more">更多</li>
  </ul>
</template>

<script>
export default {
  name: 'NavBar',
  methods: {
    back() {
      this.$router.go(-1)
    }
  }
}
</script>

<style lang="scss" scoped>
  .nav-bar {
    display: flex;
    background: #eaeaea;
    color: #2c2c2c;
    height: 72px;
    align-items: center;
    .back, .more {
      padding: 0 12px;
    }
    .title {
      flex: 1;
      text-align: center;
      font-weight: 700;
    }
  }
</style>
